package oa.service.impl;

import java.util.List;

import oa.dao.PressDao;
import oa.dao.impl.PressDaoImpl;
import oa.entity.Press;
import oa.exception.DaoException;
import oa.service.PressService;

public class PressServiceImpl implements PressService {

	PressDao pressDao = new PressDaoImpl();
	@Override
	public List<Press> selectAllPress() {
		try {
			return pressDao.selectAllPress();
		} catch (DaoException e) {
			e.printStackTrace();
		}
		return null;
	}

	@Override
	public List<Press> selectPressId(int id) {
		try {
			return pressDao.selectPressId(id);
		} catch (DaoException e) {
			e.printStackTrace();
		}
		return null;
	}

	@Override
	public List<Press> selectPressPid(int pid) {
		try {
			return pressDao.selectPressPid(pid);
		} catch (DaoException e) {
			e.printStackTrace();
		}
		return null;
	}

	@Override
	public List<Press> selectPress(int user_competence) {
		try {
			return pressDao.selectPress(user_competence);
		} catch (DaoException e) {
			e.printStackTrace();
		}
		return null;
	}

}
